package com.zwr.sheller.core.service;

import com.github.pagehelper.PageInfo;
import com.zwr.sheller.core.common.BusinessException;
import tk.mybatis.mapper.entity.Example;

import java.io.Serializable;
import java.util.List;

/**
 * @Author LSY
 * @Date 2021/11/10 10:35
 * @Version 1.0
 **/
public interface BaseService<T> {

    PageInfo<T> selectTAll(Integer page, Integer num);

    PageInfo<T> selectAllOrVague(Integer page, Integer num, T... ts) throws IllegalAccessException, BusinessException;

    T selectByPk(Serializable id) throws BusinessException;

    PageInfo<T> selectByT(Integer page, Integer num, T t);

    T insertTSelective(T t) throws BusinessException;

    void deleteTByPk(Serializable t) throws BusinessException;

    void updateTByNewT(T t) throws BusinessException;

    PageInfo<T> selectTByExample(Integer page, Integer num, Example example);

    List<T> selectAll();

    T selectByFeatures(T t);

    PageInfo<T> selectAll(Integer page,Integer size, Example example);
    
    Integer updateByNewT(T t,Example example) throws BusinessException;


}
